/************************************************************************

								Heroes IV
					  Copyright 2000, The 3DO Company

	------------------------------------------------------------------
  						 delay_effect.h

	$Header: /heroes4/delay_effect.h $

	$NoKeywords: $

 ************************************************************************/

#if !defined( DELAY_EFFECT_H_INCLUDED )
#define DELAY_EFFECT_H_INCLUDED

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include "handler.h"

class t_window;
// ----------------------------------------------------------
// class to executed a spell effect which is delayed until all
// animations cease
// ----------------------------------------------------------
class t_delayed_effect : public t_handler_base
{
public:
	virtual void execute( t_window* window ) = 0;
};

// ----------------------------------------------------------------
// execute an action when a spell animation ends
// ----------------------------------------------------------------
class t_delay_effect : public t_handler_base_1<t_window*>
{
public:
	t_delay_effect( t_delayed_effect* effect );

	virtual void operator()( t_window* window );
protected:
	t_counted_ptr<t_delayed_effect> m_effect;
};

#endif // DELAY_EFFECT_H_INCLUDED